Skip to content

Comments

Add title-prefix support to update-issue safe output#17512

Merged
pelikhan merged 4 commits intomainfrom
copilot/update-issue-safe-output
Feb 21, 2026
Merged

Add title-prefix support to update-issue safe output#17512
pelikhan merged 4 commits intomainfrom
copilot/update-issue-safe-output

Conversation

Copy link
Contributor

Copilot AI commented Feb 21, 2026

  • Add TitlePrefix string field to UpdateIssuesConfig struct in pkg/workflow/update_issue.go
  • Add title_prefix to the update_issue config builder in pkg/workflow/compiler_safe_outputs_config.go
  • Add title-prefix property to update-issue JSON schema in pkg/parser/schemas/main_workflow_schema.json
  • Add title prefix validation logic in actions/setup/js/update_issue.cjs
  • Add Go test for title-prefix parsing in pkg/workflow/update_issue_test.go
  • Add JS tests for title prefix validation in actions/setup/js/update_issue.test.cjs
  • Update docs/src/content/docs/reference/safe-outputs.md with title-prefix option and explanation
  • Regenerate docs/src/content/docs/reference/frontmatter-full.md from schema (picks up title-prefix in update-issue)
  • Regenerate docs/public/editor/autocomplete-data.json from schema
  • All tests pass, fmt/lint/build/recompile validated
Original prompt

This section details on the original issue you should resolve

<issue_title>update-issue safe output should support "title-prefix"</issue_title>
<issue_description>For consistency and added guardrails, update-issue safe output should support "title-prefix" similar to "push-to-pull-request-branch" - it should be validated and checked.</issue_description>

Comments on the Issue (you are @copilot in this section)


🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.

Co-authored-by: dsyme <7204669+dsyme@users.noreply.github.com>
Copilot AI changed the title [WIP] Update issue safe output to support title-prefix Add title-prefix support to update-issue safe output Feb 21, 2026
@dsyme dsyme marked this pull request as ready for review February 21, 2026 15:59
Copilot AI review requested due to automatic review settings February 21, 2026 15:59
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a title-prefix guardrail to safe-outputs.update-issue, preventing agents from updating issues unless the current issue title begins with a configured prefix.

Changes:

  • Extend update-issue safe-output config parsing to accept title-prefix and propagate it to the JS handler config.
  • Update the update_issue.cjs handler to validate the current issue title against the configured prefix (via a single issues.get used for both validation and body update when needed).
  • Add schema + test coverage for the new configuration in both Go and JS.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.

Show a summary per file
File Description
pkg/workflow/update_issue.go Adds TitlePrefix to UpdateIssuesConfig and parses it from title-prefix.
pkg/workflow/compiler_safe_outputs_config.go Emits title_prefix into the JS handler configuration for update_issue.
pkg/parser/schemas/main_workflow_schema.json Adds title-prefix to the safe-outputs.update-issue schema.
actions/setup/js/update_issue.cjs Stores title_prefix in update data and enforces prefix validation using issues.get.
pkg/workflow/update_issue_test.go Adds a Go test to verify title-prefix parsing.
actions/setup/js/update_issue.test.cjs Adds JS tests for title_prefix propagation and validation behavior.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Co-authored-by: dsyme <7204669+dsyme@users.noreply.github.com>
@pelikhan pelikhan merged commit b19abba into main Feb 21, 2026
82 checks passed
@pelikhan pelikhan deleted the copilot/update-issue-safe-output branch February 21, 2026 16:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

update-issue safe output should support "title-prefix"

3 participants